output "dds_info" {
  value = {
    for k, inst in huaweicloud_dds_instance.dds_instance :
    k => {
      cluster_id   = inst.id
      cluster_name = inst.name
      port         = inst.port
      nodes = [for node in inst.nodes : {
        role       = node.role
        private_ip = node.private_ip
      }]
    }
  }
}